/*
 * @Description: 会议公共数据模型
 * @Author: wind-lc
 * @version: 1.0
 * @Date: 2021-08-24 17:27:29
 * @LastEditTime: 2021-08-27 18:19:29
 * @FilePath: \cscec-pms-admin\src\components\Meeting\model.js
 */

import SelectSubCompany from '@/components/Select/SelectSubCompany'
import SelectProject from '@/components/Select/SelectProject'
import OrgTreeSelect from '@/components/OrgTreeSelect'

// 搜索列表
const searchOption = [
  // {
  //   name: '所属分公司',
  //   valueKey: 'branchComId',
  //   type: SelectSubCompany
  // },
  // {
  //   name: '所属项目',
  //   keyValue: 'branchComId',
  //   valueKey: 'projectId',
  //   type: SelectProject
  // },
  {
    name: '所属单位',
    valueKey: 'searchQuery',
    type: OrgTreeSelect,
  },
  {
    name: '会议名称',
    value: 'meetingName',
    type: 'input'
  },
  {
    name: '召开时间',
    value: 'startEndDate',
    type: 'dateRange'
  },
  {
    name: '状态',
    value: 'meetingStatus',
    type: 'select',
    data: [
      {
        value: '20',
        label: '待开始',
        color: '#1890ff'
      },
      {
        value: '30',
        label: '进行中',
        color: '#70B603'
      },
      {
        value: '40',
        label: '已完结',
        color: '#666666'
      }
    ]
  }
]
// 会议列表表头
const columns = [
  {
    title: '序号',
    width: 80,
    align: 'center',
    customRender: (text, record, index) => {
      return index + 1
    }
  },
  {
    title: '会议名称',
    width: 200,
    dataIndex: 'meetingName'
  },
  {
    title: '会议类型',
    dataIndex: 'meetingTypeName'
  },
  {
    title: '所属分公司',
    dataIndex: 'branchComName'
  },
  {
    title: '所属项目',
    dataIndex: 'projectName'
  },
  {
    title: '召开时间',
    dataIndex: 'meetingTime'
  },
  {
    title: '参会人数',
    dataIndex: 'signNum'
  },
  {
    title: '创建人',
    dataIndex: 'createUser'
  },
  {
    title: '状态',
    dataIndex: 'meetingStatusName',
    width: 100,
    scopedSlots: { customRender: 'status' }
  },
  {
    title: '操作',
    dataIndex: 'operation',
    width: 170,
    scopedSlots: { customRender: 'operation' }
  }
]
// 参会人员表头
const columnsEmployee = [
  {
    title: "员工名称",
    dataIndex: "name"
  },

  {
    title: "电话号码",
    dataIndex: "phone"
  },

  {
    title: "操作",
    dataIndex: "actions",
    width: "100px",
    scopedSlots: { customRender: "actions" }
  }
]
export {
  searchOption,
  columns,
  columnsEmployee
}